<?php
require_once "mods/class_history.php";
class atm_history extends history{
protected $subevent;

function __construct(){}
function set_subevent($subevent){$this->subevent=$subevent;}

function get_subevent(){return $this->subevent;}

function Set($id,$uid,$date,$event,$subevent,$group,$author,$comment){
	parent::Set($id,$uid,$date,$event,$group,$author,$comment);
	$this->set_subevent($subevent);
}

function Save(){
	$this->insert();
}

function insert(){
	$arValues=array();
	$arValues['id']='#id#';
	$arValues['uid']=$this->get_uid();
	$arValues['date']='now';
	$arValues['event']=$this->get_event();
	$arValues['subevent']=$this->get_subevent();
	$arValues['"group"']=$this->get_group();
	$arValues['"author"']=$this->get_author();
	$arValues['"comment"']=$this->get_comment();
	$db=postgresql::instance();
	$db->insert('atm_history',$arValues);
	
}

function Load($id){}
}
?>